3.2.40 \(\int \frac {a+b \log (c (d+e x)^n)}{\sqrt {f+g x}} \, dx\) [140]

Optimal. Leaf size=97 \[ -\frac {4 b n \sqrt {f+g x}}{g}+\frac {4 b \sqrt {e f-d g} n \tanh ^{-1}\left (\frac {\sqrt {e} \sqrt {f+g x}}{\sqrt {e f-d g}}\right )}{\sqrt {e} g}+\frac {2 \sqrt {f+g x} \left (a+b \log \left (c (d+e x)^n\right )\right )}{g} \]

[Out]

4*b*n*arctanh(e^(1/2)*(g*x+f)^(1/2)/(-d*g+e*f)^(1/2))*(-d*g+e*f)^(1/2)/g/e^(1/2)-4*b*n*(g*x+f)^(1/2)/g+2*(a+b*
ln(c*(e*x+d)^n))*(g*x+f)^(1/2)/g

________________________________________________________________________________________

Rubi [A]
time = 0.04, antiderivative size = 97, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 24, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {2442, 52, 65, 214} \begin {gather*} \frac {2 \sqrt {f+g x} \left (a+b \log \left (c (d+e x)^n\right )\right )}{g}+\frac {4 b n \sqrt {e f-d g} \tanh ^{-1}\left (\frac {\sqrt {e} \sqrt {f+g x}}{\sqrt {e f-d g}}\right )}{\sqrt {e} g}-\frac {4 b n \sqrt {f+g x}}{g} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(a + b*Log[c*(d + e*x)^n])/Sqrt[f + g*x],x]

[Out]

(-4*b*n*Sqrt[f + g*x])/g + (4*b*Sqrt[e*f - d*g]*n*ArcTanh[(Sqrt[e]*Sqrt[f + g*x])/Sqrt[e*f - d*g]])/(Sqrt[e]*g
) + (2*Sqrt[f + g*x]*(a + b*Log[c*(d + e*x)^n]))/g

Rule 52

Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[(a + b*x)^(m + 1)*((c + d*x)^n/(b*(
m + n + 1))), x] + Dist[n*((b*c - a*d)/(b*(m + n + 1))), Int[(a + b*x)^m*(c + d*x)^(n - 1), x], x] /; FreeQ[{a
, b, c, d}, x] && NeQ[b*c - a*d, 0] && GtQ[n, 0] && NeQ[m + n + 1, 0] &&  !(IGtQ[m, 0] && ( !IntegerQ[n] || (G
tQ[m, 0] && LtQ[m - n, 0]))) &&  !ILtQ[m + n + 2, 0] && IntLinearQ[a, b, c, d, m, n, x]

Rule 65

Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> With[{p = Denominator[m]}, Dist[p/b, Sub
st[Int[x^(p*(m + 1) - 1)*(c - a*(d/b) + d*(x^p/b))^n, x], x, (a + b*x)^(1/p)], x]] /; FreeQ[{a, b, c, d}, x] &
& NeQ[b*c - a*d, 0] && LtQ[-1, m, 0] && LeQ[-1, n, 0] && LeQ[Denominator[n], Denominator[m]] && IntLinearQ[a,
b, c, d, m, n, x]

Rule 214

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[-a/b, 2]/a)*ArcTanh[x/Rt[-a/b, 2]], x] /; FreeQ[{a, b},
x] && NegQ[a/b]

Rule 2442

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))*((f_.) + (g_.)*(x_))^(q_.), x_Symbol] :> Simp[(f + g*
x)^(q + 1)*((a + b*Log[c*(d + e*x)^n])/(g*(q + 1))), x] - Dist[b*e*(n/(g*(q + 1))), Int[(f + g*x)^(q + 1)/(d +
 e*x), x], x] /; FreeQ[{a, b, c, d, e, f, g, n, q}, x] && NeQ[e*f - d*g, 0] && NeQ[q, -1]

Rubi steps

\begin {align*} \int \frac {a+b \log \left (c (d+e x)^n\right )}{\sqrt {f+g x}} \, dx &=\frac {2 \sqrt {f+g x} \left (a+b \log \left (c (d+e x)^n\right )\right )}{g}-\frac {(2 b e n) \int \frac {\sqrt {f+g x}}{d+e x} \, dx}{g}\\ &=-\frac {4 b n \sqrt {f+g x}}{g}+\frac {2 \sqrt {f+g x} \left (a+b \log \left (c (d+e x)^n\right )\right )}{g}-\frac {(2 b (e f-d g) n) \int \frac {1}{(d+e x) \sqrt {f+g x}} \, dx}{g}\\ &=-\frac {4 b n \sqrt {f+g x}}{g}+\frac {2 \sqrt {f+g x} \left (a+b \log \left (c (d+e x)^n\right )\right )}{g}-\frac {(4 b (e f-d g) n) \text {Subst}\left (\int \frac {1}{d-\frac {e f}{g}+\frac {e x^2}{g}} \, dx,x,\sqrt {f+g x}\right )}{g^2}\\ &=-\frac {4 b n \sqrt {f+g x}}{g}+\frac {4 b \sqrt {e f-d g} n \tanh ^{-1}\left (\frac {\sqrt {e} \sqrt {f+g x}}{\sqrt {e f-d g}}\right )}{\sqrt {e} g}+\frac {2 \sqrt {f+g x} \left (a+b \log \left (c (d+e x)^n\right )\right )}{g}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.06, size = 83, normalized size = 0.86 \begin {gather*} \frac {2 \left (\frac {2 b \sqrt {e f-d g} n \tanh ^{-1}\left (\frac {\sqrt {e} \sqrt {f+g x}}{\sqrt {e f-d g}}\right )}{\sqrt {e}}+\sqrt {f+g x} \left (a-2 b n+b \log \left (c (d+e x)^n\right )\right )\right )}{g} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(a + b*Log[c*(d + e*x)^n])/Sqrt[f + g*x],x]

[Out]

(2*((2*b*Sqrt[e*f - d*g]*n*ArcTanh[(Sqrt[e]*Sqrt[f + g*x])/Sqrt[e*f - d*g]])/Sqrt[e] + Sqrt[f + g*x]*(a - 2*b*
n + b*Log[c*(d + e*x)^n])))/g

________________________________________________________________________________________

Maple [A]
time = 0.96, size = 140, normalized size = 1.44

method result size
derivativedivides \(\frac {2 \sqrt {g x +f}\, a +2 b \ln \left (c \left (\frac {\left (g x +f \right ) e +d g -e f}{g}\right )^{n}\right ) \sqrt {g x +f}-4 b n \sqrt {g x +f}+\frac {4 b n \arctan \left (\frac {e \sqrt {g x +f}}{\sqrt {\left (d g -e f \right ) e}}\right ) d g}{\sqrt {\left (d g -e f \right ) e}}-\frac {4 b e n \arctan \left (\frac {e \sqrt {g x +f}}{\sqrt {\left (d g -e f \right ) e}}\right ) f}{\sqrt {\left (d g -e f \right ) e}}}{g}\) \(140\)
default \(\frac {2 \sqrt {g x +f}\, a +2 b \ln \left (c \left (\frac {\left (g x +f \right ) e +d g -e f}{g}\right )^{n}\right ) \sqrt {g x +f}-4 b n \sqrt {g x +f}+\frac {4 b n \arctan \left (\frac {e \sqrt {g x +f}}{\sqrt {\left (d g -e f \right ) e}}\right ) d g}{\sqrt {\left (d g -e f \right ) e}}-\frac {4 b e n \arctan \left (\frac {e \sqrt {g x +f}}{\sqrt {\left (d g -e f \right ) e}}\right ) f}{\sqrt {\left (d g -e f \right ) e}}}{g}\) \(140\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+b*ln(c*(e*x+d)^n))/(g*x+f)^(1/2),x,method=_RETURNVERBOSE)

[Out]

2/g*((g*x+f)^(1/2)*a+b*ln(c*(((g*x+f)*e+d*g-e*f)/g)^n)*(g*x+f)^(1/2)-2*b*n*(g*x+f)^(1/2)+2*b*n/((d*g-e*f)*e)^(
1/2)*arctan(e*(g*x+f)^(1/2)/((d*g-e*f)*e)^(1/2))*d*g-2*b*e*n/((d*g-e*f)*e)^(1/2)*arctan(e*(g*x+f)^(1/2)/((d*g-
e*f)*e)^(1/2))*f)

________________________________________________________________________________________

Maxima [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: ValueError} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*(e*x+d)^n))/(g*x+f)^(1/2),x, algorithm="maxima")

[Out]

Exception raised: ValueError >> Computation failed since Maxima requested additional constraints; using the 'a
ssume' command before evaluation *may* help (example of legal syntax is 'assume(4*%e^2*f-4*%e*d*g>0)', see `as
sume?` for m

________________________________________________________________________________________

Fricas [A]
time = 0.41, size = 180, normalized size = 1.86 \begin {gather*} \left [\frac {2 \, {\left (\sqrt {-{\left (d g - f e\right )} e^{\left (-1\right )}} b n \log \left (-\frac {d g - {\left (g x + 2 \, f\right )} e - 2 \, \sqrt {g x + f} \sqrt {-{\left (d g - f e\right )} e^{\left (-1\right )}} e}{x e + d}\right ) + {\left (b n \log \left (x e + d\right ) - 2 \, b n + b \log \left (c\right ) + a\right )} \sqrt {g x + f}\right )}}{g}, -\frac {2 \, {\left (2 \, \sqrt {d g - f e} b n \arctan \left (-\frac {\sqrt {g x + f} e^{\frac {1}{2}}}{\sqrt {d g - f e}}\right ) e^{\left (-\frac {1}{2}\right )} - {\left (b n \log \left (x e + d\right ) - 2 \, b n + b \log \left (c\right ) + a\right )} \sqrt {g x + f}\right )}}{g}\right ] \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*(e*x+d)^n))/(g*x+f)^(1/2),x, algorithm="fricas")

[Out]

[2*(sqrt(-(d*g - f*e)*e^(-1))*b*n*log(-(d*g - (g*x + 2*f)*e - 2*sqrt(g*x + f)*sqrt(-(d*g - f*e)*e^(-1))*e)/(x*
e + d)) + (b*n*log(x*e + d) - 2*b*n + b*log(c) + a)*sqrt(g*x + f))/g, -2*(2*sqrt(d*g - f*e)*b*n*arctan(-sqrt(g
*x + f)*e^(1/2)/sqrt(d*g - f*e))*e^(-1/2) - (b*n*log(x*e + d) - 2*b*n + b*log(c) + a)*sqrt(g*x + f))/g]

________________________________________________________________________________________

Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 326 vs. \(2 (88) = 176\).
time = 16.74, size = 326, normalized size = 3.36 \begin {gather*} \begin {cases} \frac {- \frac {2 a f}{\sqrt {f + g x}} - 2 a \left (- \frac {f}{\sqrt {f + g x}} - \sqrt {f + g x}\right ) - 2 b f \left (\frac {2 e n \operatorname {atan}{\left (\frac {1}{\sqrt {\frac {e}{d g - e f}} \sqrt {f + g x}} \right )}}{\sqrt {\frac {e}{d g - e f}} \left (d g - e f\right )} + \frac {\log {\left (c \left (d + e x\right )^{n} \right )}}{\sqrt {f + g x}}\right ) - 2 b \left (- \frac {2 e n \left (- \frac {g \sqrt {f + g x}}{e} - \frac {g \operatorname {atan}{\left (\frac {1}{\sqrt {\frac {e}{d g - e f}} \sqrt {f + g x}} \right )}}{e \sqrt {\frac {e}{d g - e f}}}\right )}{g} - f \left (\frac {2 e n \operatorname {atan}{\left (\frac {1}{\sqrt {\frac {e}{d g - e f}} \sqrt {f + g x}} \right )}}{\sqrt {\frac {e}{d g - e f}} \left (d g - e f\right )} + \frac {\log {\left (c \left (d - \frac {e f}{g} + \frac {e \left (f + g x\right )}{g}\right )^{n} \right )}}{\sqrt {f + g x}}\right ) - \sqrt {f + g x} \log {\left (c \left (d - \frac {e f}{g} + \frac {e \left (f + g x\right )}{g}\right )^{n} \right )}\right )}{g} & \text {for}\: g \neq 0 \\\frac {a x + b \left (- e n \left (- \frac {d \left (\begin {cases} \frac {x}{d} & \text {for}\: e = 0 \\\frac {\log {\left (d + e x \right )}}{e} & \text {otherwise} \end {cases}\right )}{e} + \frac {x}{e}\right ) + x \log {\left (c \left (d + e x\right )^{n} \right )}\right )}{\sqrt {f}} & \text {otherwise} \end {cases} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*ln(c*(e*x+d)**n))/(g*x+f)**(1/2),x)

[Out]

Piecewise(((-2*a*f/sqrt(f + g*x) - 2*a*(-f/sqrt(f + g*x) - sqrt(f + g*x)) - 2*b*f*(2*e*n*atan(1/(sqrt(e/(d*g -
 e*f))*sqrt(f + g*x)))/(sqrt(e/(d*g - e*f))*(d*g - e*f)) + log(c*(d + e*x)**n)/sqrt(f + g*x)) - 2*b*(-2*e*n*(-
g*sqrt(f + g*x)/e - g*atan(1/(sqrt(e/(d*g - e*f))*sqrt(f + g*x)))/(e*sqrt(e/(d*g - e*f))))/g - f*(2*e*n*atan(1
/(sqrt(e/(d*g - e*f))*sqrt(f + g*x)))/(sqrt(e/(d*g - e*f))*(d*g - e*f)) + log(c*(d - e*f/g + e*(f + g*x)/g)**n
)/sqrt(f + g*x)) - sqrt(f + g*x)*log(c*(d - e*f/g + e*(f + g*x)/g)**n)))/g, Ne(g, 0)), ((a*x + b*(-e*n*(-d*Pie
cewise((x/d, Eq(e, 0)), (log(d + e*x)/e, True))/e + x/e) + x*log(c*(d + e*x)**n)))/sqrt(f), True))

________________________________________________________________________________________

Giac [A]
time = 5.87, size = 110, normalized size = 1.13 \begin {gather*} \frac {2 \, {\left ({\left (2 \, {\left (\frac {{\left (d g - f e\right )} \arctan \left (\frac {\sqrt {g x + f} e}{\sqrt {d g e - f e^{2}}}\right ) e^{\left (-1\right )}}{\sqrt {d g e - f e^{2}}} - \sqrt {g x + f} e^{\left (-1\right )}\right )} e + \sqrt {g x + f} \log \left (x e + d\right )\right )} b n + \sqrt {g x + f} b \log \left (c\right ) + \sqrt {g x + f} a\right )}}{g} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*(e*x+d)^n))/(g*x+f)^(1/2),x, algorithm="giac")

[Out]

2*((2*((d*g - f*e)*arctan(sqrt(g*x + f)*e/sqrt(d*g*e - f*e^2))*e^(-1)/sqrt(d*g*e - f*e^2) - sqrt(g*x + f)*e^(-
1))*e + sqrt(g*x + f)*log(x*e + d))*b*n + sqrt(g*x + f)*b*log(c) + sqrt(g*x + f)*a)/g

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {a+b\,\ln \left (c\,{\left (d+e\,x\right )}^n\right )}{\sqrt {f+g\,x}} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a + b*log(c*(d + e*x)^n))/(f + g*x)^(1/2),x)

[Out]

int((a + b*log(c*(d + e*x)^n))/(f + g*x)^(1/2), x)

________________________________________________________________________________________